<?php
$this->breadcrumbs=array(
        'Фотографии'=>array('index'),
        FotoC::model()->getName($model->id_foto_cat)=>array('foto/category&c='.$model->id_foto_cat),
        $model->name,
);

$this->menu=array(
        array('label'=>'Просмотр альбомов', 'url'=>array('index')),
        array('label'=>'Добавить', 'url'=>array('create')),
        array('label'=>'Изменить', 'url'=>array('update', 'id'=>$model->id_foto)),
        array('label'=>'Удалить', 'url'=>'#', 'linkOptions'=>array('submit'=>array('delete','id'=>$model->id_foto),'confirm'=>'Are you sure to delete this item?')),
        array('label'=>'Управление', 'url'=>array('admin')),
);
?>

<div style="text-align: right; padding-bottom: 15px;">

    <?php
    $next = Foto::nextImage($model->id_foto,$model->id_foto_cat);
    $back = Foto::backImage($model->id_foto,$model->id_foto_cat);
    echo Foto::countes($model->id_foto , $model->id_foto_cat);
    ?>
</div>
<div id="foto" >

    <div id="of">

        <a href="<?php echo $url=$this->createUrl("foto/view", array('id'=>$next));?>">
            <img alt="<?php echo $model->name?>" src="media/foto/<?php echo $model->link?>">
        </a>

    </div>
    <div id="fotdesc">
        <div id="fdesc"><?php echo $model->description?></div>
        <div id="fau">Выложил: <?php echo $model->autor?>
         (<?php echo $model->c_date?>)</div>
    </div>
    <div id="fot">
        <?php
        echo '<span id="b"><a href="'.$url=$this->createUrl("foto/view", array('id'=>$back)).'"><< Прошлoe фото</a></span>';
        echo '|';
        echo '<span id="n"><a href="'.$url=$this->createUrl("foto/view", array('id'=>$next)).'">Следуещее фото >></a></span>';
        ?>
    </div>
</div>

<?php //echo $this->renderPartial('../coments/comen', array('coment_model'=>$coment_model,'dataProvider'=>$dataProvider)); ?>
